All Questions
Tagged with programming-logicdevelopment-methodologies
2 questions
5votes
1answer
949views
How to guarantee invariants / Inner logic in setter methods
According to DDD-principles I use factory-methods to create consistent objects and to ensure that the objects are in the right state. Now I'm in doubt about inner logic of setter methods. I'm tied up ...
21votes
9answers
9kviews
How to turn truth table into smallest possible if / else block
How can I take a truth table and turn it into a compacted if block? For instance, let's say I have this truth table where A and B are conditions and x, y and z are possible actions: A B | x y z -----...